<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class Address extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('address', function (Blueprint $table) {
            $table->mediumInteger('address_id')->increments();
            $table->mediumInteger('member_id')->dufault(0)->unique();
            $table->string('true_name',50);
            $table->mediumInteger('area_id')->default(0);
            $table->mediumInteger('city_id');
            $table->string('area_info',255)->default('');
            $table->string('address',255);
            $table->string('tel_phone',20);
            $table->string('mob_phone',15);
            $table->enum('is_default',array(0,1))->default();
            $table->integer('dlyp')->default(0);
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('address');
    }
}
